<?php
/**
 * Pert Library
 * Test
 * Postgre Classes
 *
 * @author	Emre Hasegeli <hasegeli@gmail.com>
 * @license	GNU General Public License v3
 */

namespace Pert;

require '../Postgre.php';

$postgre = new Postgre('vademecum',
		'test-db.vademecumonline.com.tr',
		'5432',
		'Pert',
		'kalemLik31');

$resultArrayArray = $postgre->SelectResultArrayArray('SELECT * FROM Pert."Table_name"');

foreach($resultArrayArray AS $arrayId => $resultArray)
	foreach($resultArray AS $id => $result)
		echo '<p >' . $arrayId . '|' . $id . '|' . $result . '</p>';

$resultArray = $postgre->SelectResultArray('SELECT * FROM Pert."Table_name" WHERE "Table" = 10');

foreach($resultArray AS $id => $result)
	echo '<p >' . $id . '|' . $result . '</p>';

$result = $postgre->SelectResult('SELECT "Name" FROM Pert."Table_name" WHERE "Table" = 10');

echo '<p >' . $result . '</p>';